package org.example.customstarter.controller;

import org.example.customstarter.service.CustomService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/example")
public class ExampleController {

    @Autowired
    private CustomService customService;

    @GetMapping("/process")
    public String processExample() {
        // 使用自定义starter中的组件
        String result = customService.processString("Hello, Custom Starter!");
        return "Processed Result: " + result;
    }
}